import Vue from 'vue'
import Vuex from 'vuex'
Vue.use(Vuex)
const state = {
    username: localStorage.getItem('username') || ''
}
const mutations = {
    setUsername: (state, username) => {
        state.username = username
    }
}
export default new Vuex.Store({
    state,
    mutations
})